from django.urls import path
from . import views

urlpatterns = [
    # Sort 分类【只查】
    # 获取分类，如衣服、化妆品等分类
    path('get_sorts/', views.GetSorts, name='GetSorts'),

    # Category 查增(改)删
    # 类别，传入分类ID，获取衣服的属性分类，如种类、颜色、位置
    path('get_categories/',   views.GetCategories,    name='GetCategories'),
    path('update_category/',  views.UpdateCategory,   name='UpdateCategory'),
    path('del_category/',     views.DelCategory,      name='DelCategory'),

    # Property 查增改删
    # 属性，传入属性分类ID，如衣服种类，获取种类属性，如上衣(T恤、卫衣、衬衫)、下装(牛仔裤、运动裤)
    path('get_properties/',   views.GetProperties,    name='GetProperties'),
    path('update_property/',  views.UpdateProperty,   name='UpdateProperty'),
    path('del_property/',     views.DelProperty,      name='DelProperty'),

    # Object 查增改删
    # 物品，传入分类ID，如衣服，获取物品，如短袖1
    path('get_objects/',    views.GetObjects,   name='GetObjects'),
    path('get_object_detail/',  views.GetObjectDetail,  name='GetObjectDetail'),
    path('update_object/',  views.UpdateObject, name='UpdateObject'),
    path('del_object/',     views.DelObject,    name='DelObject'),

    # Suit 增删改查
    # 套装，传入分类ID，获取套装
    path('get_suits/',    views.GetSuits,   name='GetSuits'),
    path('get_suit_objects/',    views.GetSuitObjects,   name='GetSuitObjects'),
    path('update_suit/',  views.UpdateSuit, name='UpdateSuit'),
    path('del_suit/',     views.DelSuit,    name='DelSuit'),

    # 更新图片接口
    path('update_image/', views.UpdateImage,    name='UpdateImage'),

    # Record 增删改查
    # 记录，传入日期，获取穿着记录
    path('get_records/',      views.GetRecords,   name='GetRecords'),
    path('get_day_records/',  views.GetDayRecord, name='GetDayRecord'),
    path('update_record/',    views.UpdateRecord, name='UpdateRecord'),
    path('del_record/',       views.DelRecord,    name='DelRecord'),


    # 各类统计
    # 统计查询接口
]